/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */

package com.ejb;

import com.Person;
import java.util.ArrayList;
import java.util.List;
import javax.ejb.Stateless;

/**
 *
 * @author cubika
 */
@Stateless
public class PersonaEJB implements PersonaEJBLocal {

    @Override
    public List<Person> getAllPerson() {
        
        List<Person> list=new ArrayList<Person>();

        Person p = new Person();
        p.setLastname("perez");
        p.setFirstname("juan");
        list.add(p);
        Person p2 = new Person();
        p2.setLastname("Arias");
        p2.setFirstname("Diego");
        list.add(p2);
        Person p3 = new Person();
        p3.setLastname("Hernandez");
        p3.setFirstname("Fernando");
        list.add(p3);
        Person p4 = new Person();
        p4.setLastname("flores");
        p4.setFirstname("Gabriel");
        list.add(p4);
        

        return list;
    }
    
    // Add business logic below. (Right-click in editor and choose
    // "Insert Code > Add Business Method")
 
}
